<?php
include('util/bloqueDeSeguridad.php');

$array = "";
if (isset($_GET['array'])) {
    $array = $_GET['array'];
}

$tituloPagina = "Exportar SMG";
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <title><?php echo $tituloPagina; ?></title>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
        <script src="Content/Scripts/jquery-1.7.2.js" type="text/javascript"></script>
        <script src="Content/Scripts/jquery-ui-1.8.20.custom.min.js" type="text/javascript"></script>
        <script src="Content/Scripts/jquery.ui.multiselect-4.3.3.js" type="text/javascript"></script>

        <script src="js/i18n/grid.locale-es.js" type="text/javascript"></script>

        <script src="Content/Scripts/jquery.jqGrid-4.3.3.min.js" type="text/javascript"></script>
        <script src="Content/Scripts/jquery.droppy.js" type="text/javascript"></script>
        <script src="Content/Scripts/jquery.validate.min.js" type="text/javascript"></script>
        <script src="Content/Scripts/jquery.validate.unobtrusive.min.js" type="text/javascript"></script>
        <script src="js/fancybox.js" type="text/javascript"></script>
        <link href="Content/Site.css" rel="stylesheet" type="text/css" />
        <link href="Content/jquery.css" rel="stylesheet" type="text/css" />
        <link href="Content/themes/redmond/jquery-ui-1.8.20.custom.css" rel="stylesheet" type="text/css" />
        <link href="Content/jqGrid/jquery-ui-jqgrid.css" rel="stylesheet" type="text/css" /> 
        <link rel="stylesheet" media="screen" type="text/css" href="Content/smoothness.datepick.css" />
        <script type="text/javascript" src="js/jquery.datepick.js"></script>
        <script type="text/javascript" src="js/jquery.datepick-es.js" ></script>
        
        <script>
        function GeneraExcel()
        {
            window.location.href = "SolicitudExportarSmg.php?array=" + '<?php echo $array; ?>';
         }
         
        function GeneraTxt()
        {
            window.location.href = "SolicitudExportSmgTxt.php?array=" + '<?php echo $array; ?>';
         } 
   	function CerrarVentanaFancy()
   	{
   		window.parent.parent.location.reload();
   	}            
        </script>        
    </head>
    <body>
        <table>
            <tr>
                <td>
                    Pantalla de Exportacion de Archivos de <b>SMG</b>
                </td>
            </tr>
            <tr><td>&nbsp;</td></tr>
            <tr>
                <td>
                    <input type="button" value="Exportar SMG TXT" id="exportarTxt" onclick="javascript:GeneraTxt()" />
                </td>
            </tr>
            <tr>
                <td>                    
                    <input type="button" value="Exportar SMG Excel" id="exportarExcel" onclick="javascript:GeneraExcel()" />                
                </td>
            </tr>
            <tr><td>&nbsp;</td></tr>
            <tr>
                <td>
                    <input type="button" value="Cerrar Ventana" onclick="javascript:CerrarVentanaFancy();">
                </td>
            </tr>  
            </tr>
        </table>        
    </body>  
</html>    